package cn.ggsaas.common.controller;


import cn.ggsaas.common.api.SysAreaService;
import cn.ggsaas.common.pojo.SysArea;
import com.baomidou.mybatisplus.extension.api.R;
import org.apache.dubbo.config.annotation.Reference;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 * 区域基础数据表 前端控制器
 * </p>
 *
 * @author ggsaas-MpGenerator
 * @since 2020-09-01
 */
@RestController
@RequestMapping("/common")
public class CommonController {
    @Reference
    private SysAreaService sysAreaService;

    @GetMapping("area")
    public R<List<SysArea>> getArea() {
        return R.ok(sysAreaService.list());
    }
}

